package com.bjx.demo.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.bjx.common.data.scope.annotation.DataScope;
import com.bjx.demo.domain.entity.VacationEntity;
import com.bjx.demo.domain.query.VacationQuery;
import com.bjx.demo.domain.vo.VacationVO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

/**
 * @desc: 请假信息Mapper
 * @author: liushuai
 * @date: 2022/10/20
 */
@Mapper
public interface VacationMapper extends BaseMapper<VacationEntity> {
    /**
     * 分页查询请假信息
     * @param page
     * @param vacationQuery
     * @return: IPage<VacationVO>
     * @Author: liushuai
     * @Date: 2022/10/20
     */
    @DataScope(userId = "apply_user",orgId = "org_id",comId = "com_id")
    IPage<VacationVO> listVacationPage(Page page,@Param("query") VacationQuery vacationQuery);
}
